#include <bits/stdc++.h>

using namespace std;

int n,t;
float s;
struct bag{
    float x;
    float y;
    float price;
}a[110];
bool cmp(bag a,bag b){
    return a.price>b.price;
}
int main()
{
    cin>>n>>t;
    for(int i=1;i<=n;i++){
        cin>>a[i].x>>a[i].y;
        a[i].price = a[i].y/a[i].x;
    }
    sort(1+a,a+1+n,cmp);
    for(int i=1;i<=n;i++){
        if(t>=a[i].x){
            s+=a[i].y;
            t-=a[i].x;
        }else{
            s+=t*a[i].price;
            t=0;
            break;
        }
    }
    printf("%.2f",s);
    return 0;
}
